using System.Collections.Generic;
using UnityEngine;

public class Arrow : MonoBehaviour
{
	public List<UIWidget> colorableParts = new List<UIWidget>();

	public Transform widgetToAnimate;

	public float maxScale = 2f;

	public float minScale = 2f;

	public float duration = 0.1f;

	public void SetColor(Color color)
	{
		foreach (UIWidget colorablePart in colorableParts)
		{
			float alpha = colorablePart.alpha;
			colorablePart.color = color;
			colorablePart.alpha = alpha;
		}
	}

	public void AnimateSelection()
	{
		Vector3 scale = new Vector3(maxScale, maxScale, maxScale);
		Vector3 localScale = new Vector3(minScale, minScale, minScale);
		widgetToAnimate.localScale = localScale;
		TweenScale.Begin(widgetToAnimate.gameObject, duration, scale);
	}
}
